/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package tpdisenio2009.filters;

import tpdisenio2009.model.beans.RealTeam;

/**
 *
 * @author Pablito
 */
public class AFAPlayerFilter {

    private RealTeam realTeam;
    private Integer minCotization;
    private Integer maxCotization;
    private String position;

    public AFAPlayerFilter() {
        realTeam = null;
        minCotization = null;
        maxCotization = null;
        position = null;
    }

    public void setClub ( RealTeam club ) {
        realTeam = club;
    }

    public RealTeam getClub ( ) {
        if ( realTeam.getName().equals("Todos") ) {
            return null;
        } else {
            return realTeam;
        }
    }

    public void setCotizationRange ( Integer min, Integer max ) {
        minCotization = min;
        maxCotization = max;
    }

    public void setMinCotizationRange ( Integer min ) {
        minCotization = min;
    }

    public Integer getMinCotization ( ) {
        return minCotization;
    }

    public void setMaxCotizationRange ( Integer max ) {
        maxCotization = max;
    }

    public Integer getMaxCotization ( ) {
        return maxCotization;
    }

    public void setPosition ( String pos ) {
        position = pos;        
    }

    public String getPosicion ( ) {
        if ( position.equals( "Todos" ) ) {
            return null;
        } else {
            return position;
        }
    }
}